package com.esri.core.internal.io.handler;

import java.io.InputStream;
import java.util.Map;

/* loaded from: classes.dex */
public class a extends c {
    private static final long serialVersionUID = 1;

    public static byte[] a(String str, Map<String, String> map) throws Exception {
        return a(str, map, (n) null);
    }

    public static byte[] a(String str, Map<String, String> map, n nVar) throws Exception {
        return a(str, map, nVar, (ResponseListener) null);
    }

    /* JADX WARN: Code restructure failed: missing block: B:287:0x014b, code lost:
        if (r20.onResponseInterception(r10) == false) goto L71;
     */
    /* JADX WARN: Code restructure failed: missing block: B:288:0x014d, code lost:
        if (r12 == null) goto L140;
     */
    /* JADX WARN: Code restructure failed: missing block: B:289:0x014f, code lost:
        r12.consumeContent();
     */
    /* JADX WARN: Code restructure failed: missing block: B:291:0x0153, code lost:
        r0 = move-exception;
     */
    /* JADX WARN: Code restructure failed: missing block: B:292:0x0154, code lost:
        r0.printStackTrace();
     */
    /* JADX WARN: Code restructure failed: missing block: B:293:0x0158, code lost:
        return null;
     */
    /* JADX WARN: Code restructure failed: missing block: B:295:0x015a, code lost:
        r0 = move-exception;
     */
    /* JADX WARN: Code restructure failed: missing block: B:296:0x015b, code lost:
        r1 = r0;
        r10 = r12;
     */
    /* JADX WARN: Code restructure failed: missing block: B:297:0x015f, code lost:
        r0 = e;
     */
    /* JADX WARN: Code restructure failed: missing block: B:298:0x0160, code lost:
        r14 = r12;
     */
    /* JADX WARN: Code restructure failed: missing block: B:306:0x0170, code lost:
        r12 = null;
     */
    /* JADX WARN: Code restructure failed: missing block: B:406:?, code lost:
        return null;
     */
    /* JADX WARN: Code restructure failed: missing block: B:407:?, code lost:
        return null;
     */
    /* JADX WARN: Removed duplicated region for block: B:223:0x0036 A[Catch: all -> 0x0022, Exception -> 0x0027, TRY_ENTER, TryCatch #6 {all -> 0x0022, blocks: (B:209:0x0016, B:212:0x001b, B:220:0x0030, B:223:0x0036, B:226:0x003e, B:229:0x0046, B:235:0x0055, B:236:0x005d, B:231:0x004a, B:233:0x004e), top: B:386:0x0016 }] */
    /* JADX WARN: Removed duplicated region for block: B:231:0x004a A[Catch: all -> 0x0022, Exception -> 0x0027, TRY_ENTER, TryCatch #6 {all -> 0x0022, blocks: (B:209:0x0016, B:212:0x001b, B:220:0x0030, B:223:0x0036, B:226:0x003e, B:229:0x0046, B:235:0x0055, B:236:0x005d, B:231:0x004a, B:233:0x004e), top: B:386:0x0016 }] */
    /* JADX WARN: Removed duplicated region for block: B:239:0x007b A[Catch: Exception -> 0x019c, all -> 0x01ac, TryCatch #8 {all -> 0x01ac, blocks: (B:335:0x01a8, B:339:0x01b3, B:340:0x01b6, B:343:0x01c0, B:345:0x01cd, B:346:0x01d2, B:347:0x01d3, B:348:0x01d4, B:350:0x01d8, B:352:0x01e9, B:354:0x01f1, B:356:0x01f9, B:359:0x0202, B:360:0x0203, B:367:0x0238, B:368:0x023d, B:369:0x023e, B:237:0x0075, B:239:0x007b, B:241:0x0081, B:243:0x008f, B:245:0x0095, B:247:0x00a3, B:252:0x00be, B:265:0x00d6, B:268:0x00de, B:269:0x00e1, B:271:0x00eb, B:272:0x00fd, B:274:0x0110, B:276:0x011c, B:278:0x0122, B:280:0x0130, B:283:0x013f, B:284:0x0144, B:311:0x017b, B:302:0x0168, B:303:0x016d, B:307:0x0172, B:308:0x0177, B:258:0x00c8, B:259:0x00cb, B:262:0x00cf), top: B:388:0x0075 }] */
    /* JADX WARN: Removed duplicated region for block: B:252:0x00be A[Catch: Exception -> 0x019c, all -> 0x01ac, TRY_ENTER, TryCatch #8 {all -> 0x01ac, blocks: (B:335:0x01a8, B:339:0x01b3, B:340:0x01b6, B:343:0x01c0, B:345:0x01cd, B:346:0x01d2, B:347:0x01d3, B:348:0x01d4, B:350:0x01d8, B:352:0x01e9, B:354:0x01f1, B:356:0x01f9, B:359:0x0202, B:360:0x0203, B:367:0x0238, B:368:0x023d, B:369:0x023e, B:237:0x0075, B:239:0x007b, B:241:0x0081, B:243:0x008f, B:245:0x0095, B:247:0x00a3, B:252:0x00be, B:265:0x00d6, B:268:0x00de, B:269:0x00e1, B:271:0x00eb, B:272:0x00fd, B:274:0x0110, B:276:0x011c, B:278:0x0122, B:280:0x0130, B:283:0x013f, B:284:0x0144, B:311:0x017b, B:302:0x0168, B:303:0x016d, B:307:0x0172, B:308:0x0177, B:258:0x00c8, B:259:0x00cb, B:262:0x00cf), top: B:388:0x0075 }] */
    /* JADX WARN: Removed duplicated region for block: B:265:0x00d6 A[Catch: Exception -> 0x019c, all -> 0x01ac, TRY_LEAVE, TryCatch #8 {all -> 0x01ac, blocks: (B:335:0x01a8, B:339:0x01b3, B:340:0x01b6, B:343:0x01c0, B:345:0x01cd, B:346:0x01d2, B:347:0x01d3, B:348:0x01d4, B:350:0x01d8, B:352:0x01e9, B:354:0x01f1, B:356:0x01f9, B:359:0x0202, B:360:0x0203, B:367:0x0238, B:368:0x023d, B:369:0x023e, B:237:0x0075, B:239:0x007b, B:241:0x0081, B:243:0x008f, B:245:0x0095, B:247:0x00a3, B:252:0x00be, B:265:0x00d6, B:268:0x00de, B:269:0x00e1, B:271:0x00eb, B:272:0x00fd, B:274:0x0110, B:276:0x011c, B:278:0x0122, B:280:0x0130, B:283:0x013f, B:284:0x0144, B:311:0x017b, B:302:0x0168, B:303:0x016d, B:307:0x0172, B:308:0x0177, B:258:0x00c8, B:259:0x00cb, B:262:0x00cf), top: B:388:0x0075 }] */
    /* JADX WARN: Removed duplicated region for block: B:335:0x01a8 A[Catch: all -> 0x01ac, TRY_ENTER, TryCatch #8 {all -> 0x01ac, blocks: (B:335:0x01a8, B:339:0x01b3, B:340:0x01b6, B:343:0x01c0, B:345:0x01cd, B:346:0x01d2, B:347:0x01d3, B:348:0x01d4, B:350:0x01d8, B:352:0x01e9, B:354:0x01f1, B:356:0x01f9, B:359:0x0202, B:360:0x0203, B:367:0x0238, B:368:0x023d, B:369:0x023e, B:237:0x0075, B:239:0x007b, B:241:0x0081, B:243:0x008f, B:245:0x0095, B:247:0x00a3, B:252:0x00be, B:265:0x00d6, B:268:0x00de, B:269:0x00e1, B:271:0x00eb, B:272:0x00fd, B:274:0x0110, B:276:0x011c, B:278:0x0122, B:280:0x0130, B:283:0x013f, B:284:0x0144, B:311:0x017b, B:302:0x0168, B:303:0x016d, B:307:0x0172, B:308:0x0177, B:258:0x00c8, B:259:0x00cb, B:262:0x00cf), top: B:388:0x0075 }] */
    /* JADX WARN: Removed duplicated region for block: B:339:0x01b3 A[Catch: all -> 0x01ac, TryCatch #8 {all -> 0x01ac, blocks: (B:335:0x01a8, B:339:0x01b3, B:340:0x01b6, B:343:0x01c0, B:345:0x01cd, B:346:0x01d2, B:347:0x01d3, B:348:0x01d4, B:350:0x01d8, B:352:0x01e9, B:354:0x01f1, B:356:0x01f9, B:359:0x0202, B:360:0x0203, B:367:0x0238, B:368:0x023d, B:369:0x023e, B:237:0x0075, B:239:0x007b, B:241:0x0081, B:243:0x008f, B:245:0x0095, B:247:0x00a3, B:252:0x00be, B:265:0x00d6, B:268:0x00de, B:269:0x00e1, B:271:0x00eb, B:272:0x00fd, B:274:0x0110, B:276:0x011c, B:278:0x0122, B:280:0x0130, B:283:0x013f, B:284:0x0144, B:311:0x017b, B:302:0x0168, B:303:0x016d, B:307:0x0172, B:308:0x0177, B:258:0x00c8, B:259:0x00cb, B:262:0x00cf), top: B:388:0x0075 }] */
    /* JADX WARN: Removed duplicated region for block: B:343:0x01c0 A[Catch: all -> 0x01ac, TRY_ENTER, TryCatch #8 {all -> 0x01ac, blocks: (B:335:0x01a8, B:339:0x01b3, B:340:0x01b6, B:343:0x01c0, B:345:0x01cd, B:346:0x01d2, B:347:0x01d3, B:348:0x01d4, B:350:0x01d8, B:352:0x01e9, B:354:0x01f1, B:356:0x01f9, B:359:0x0202, B:360:0x0203, B:367:0x0238, B:368:0x023d, B:369:0x023e, B:237:0x0075, B:239:0x007b, B:241:0x0081, B:243:0x008f, B:245:0x0095, B:247:0x00a3, B:252:0x00be, B:265:0x00d6, B:268:0x00de, B:269:0x00e1, B:271:0x00eb, B:272:0x00fd, B:274:0x0110, B:276:0x011c, B:278:0x0122, B:280:0x0130, B:283:0x013f, B:284:0x0144, B:311:0x017b, B:302:0x0168, B:303:0x016d, B:307:0x0172, B:308:0x0177, B:258:0x00c8, B:259:0x00cb, B:262:0x00cf), top: B:388:0x0075 }] */
    /* JADX WARN: Removed duplicated region for block: B:348:0x01d4 A[Catch: all -> 0x01ac, TryCatch #8 {all -> 0x01ac, blocks: (B:335:0x01a8, B:339:0x01b3, B:340:0x01b6, B:343:0x01c0, B:345:0x01cd, B:346:0x01d2, B:347:0x01d3, B:348:0x01d4, B:350:0x01d8, B:352:0x01e9, B:354:0x01f1, B:356:0x01f9, B:359:0x0202, B:360:0x0203, B:367:0x0238, B:368:0x023d, B:369:0x023e, B:237:0x0075, B:239:0x007b, B:241:0x0081, B:243:0x008f, B:245:0x0095, B:247:0x00a3, B:252:0x00be, B:265:0x00d6, B:268:0x00de, B:269:0x00e1, B:271:0x00eb, B:272:0x00fd, B:274:0x0110, B:276:0x011c, B:278:0x0122, B:280:0x0130, B:283:0x013f, B:284:0x0144, B:311:0x017b, B:302:0x0168, B:303:0x016d, B:307:0x0172, B:308:0x0177, B:258:0x00c8, B:259:0x00cb, B:262:0x00cf), top: B:388:0x0075 }] */
    /* JADX WARN: Removed duplicated region for block: B:379:0x0241 A[EXC_TOP_SPLITTER, SYNTHETIC] */
    /* JADX WARN: Removed duplicated region for block: B:383:0x017b A[EXC_TOP_SPLITTER, SYNTHETIC] */
    /* JADX WARN: Removed duplicated region for block: B:389:0x0192 A[EXC_TOP_SPLITTER, SYNTHETIC] */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
        To view partially-correct code enable 'Show inconsistent code' option in preferences
    */
    public static byte[] a(java.lang.String r17, java.util.Map<java.lang.String, java.lang.String> r18, com.esri.core.internal.io.handler.n r19, com.esri.core.internal.io.handler.ResponseListener r20) throws java.lang.Exception {
        /*
            Method dump skipped, instructions count: 589
            To view this dump change 'Code comments level' option to 'DEBUG'
        */
        throw new UnsupportedOperationException("Method not decompiled: com.esri.core.internal.io.handler.a.a(java.lang.String, java.util.Map, com.esri.core.internal.io.handler.n, com.esri.core.internal.io.handler.ResponseListener):byte[]");
    }

    public static InputStream b(String str, Map<String, String> map, n nVar) throws Exception {
        return a(str, map, -1L, 1, nVar, (ResponseListener) null);
    }

    public static InputStream a(String str, Map<String, String> map, long j, n nVar, ResponseListener responseListener) throws Exception {
        return a(str, map, j, 1, nVar, responseListener);
    }

    /* JADX WARN: Removed duplicated region for block: B:219:0x004f A[Catch: Exception -> 0x001e, TRY_ENTER, TRY_LEAVE, TryCatch #3 {Exception -> 0x001e, blocks: (B:194:0x0012, B:197:0x0017, B:206:0x002b, B:208:0x0033, B:211:0x003b, B:213:0x0043, B:262:0x010b, B:264:0x0115, B:288:0x0186, B:289:0x018b, B:314:0x021a, B:219:0x004f), top: B:367:0x0012 }] */
    /* JADX WARN: Removed duplicated region for block: B:258:0x0100 A[Catch: Exception -> 0x008c, TRY_LEAVE, TryCatch #4 {Exception -> 0x008c, blocks: (B:225:0x0070, B:232:0x00a6, B:234:0x00ac, B:236:0x00ba, B:238:0x00c0, B:240:0x00ce, B:245:0x00e9, B:258:0x0100, B:261:0x0108, B:290:0x018c, B:291:0x0191, B:251:0x00f3, B:252:0x00f6, B:255:0x00fa, B:293:0x0194, B:295:0x019a, B:297:0x01a8, B:299:0x01b0, B:301:0x01ba, B:303:0x01c0, B:305:0x01ce, B:306:0x01d3, B:308:0x01da, B:309:0x01de, B:310:0x01ef, B:312:0x020b, B:318:0x0223, B:321:0x0228, B:322:0x022a), top: B:368:0x0070 }] */
    /* JADX WARN: Removed duplicated region for block: B:308:0x01da A[Catch: Exception -> 0x008c, LOOP:0: B:306:0x01d3->B:308:0x01da, LOOP_END, TryCatch #4 {Exception -> 0x008c, blocks: (B:225:0x0070, B:232:0x00a6, B:234:0x00ac, B:236:0x00ba, B:238:0x00c0, B:240:0x00ce, B:245:0x00e9, B:258:0x0100, B:261:0x0108, B:290:0x018c, B:291:0x0191, B:251:0x00f3, B:252:0x00f6, B:255:0x00fa, B:293:0x0194, B:295:0x019a, B:297:0x01a8, B:299:0x01b0, B:301:0x01ba, B:303:0x01c0, B:305:0x01ce, B:306:0x01d3, B:308:0x01da, B:309:0x01de, B:310:0x01ef, B:312:0x020b, B:318:0x0223, B:321:0x0228, B:322:0x022a), top: B:368:0x0070 }] */
    /* JADX WARN: Removed duplicated region for block: B:312:0x020b A[Catch: Exception -> 0x008c, JsonParseException -> 0x022b, TRY_LEAVE, TryCatch #4 {Exception -> 0x008c, blocks: (B:225:0x0070, B:232:0x00a6, B:234:0x00ac, B:236:0x00ba, B:238:0x00c0, B:240:0x00ce, B:245:0x00e9, B:258:0x0100, B:261:0x0108, B:290:0x018c, B:291:0x0191, B:251:0x00f3, B:252:0x00f6, B:255:0x00fa, B:293:0x0194, B:295:0x019a, B:297:0x01a8, B:299:0x01b0, B:301:0x01ba, B:303:0x01c0, B:305:0x01ce, B:306:0x01d3, B:308:0x01da, B:309:0x01de, B:310:0x01ef, B:312:0x020b, B:318:0x0223, B:321:0x0228, B:322:0x022a), top: B:368:0x0070 }] */
    /* JADX WARN: Removed duplicated region for block: B:317:0x0221  */
    /* JADX WARN: Removed duplicated region for block: B:327:0x0231 A[Catch: Exception -> 0x023a, TRY_ENTER, TRY_LEAVE, TryCatch #5 {Exception -> 0x023a, blocks: (B:222:0x005f, B:229:0x008f, B:327:0x0231), top: B:369:0x005f }] */
    /* JADX WARN: Removed duplicated region for block: B:337:0x0247  */
    /* JADX WARN: Removed duplicated region for block: B:339:0x024c  */
    /* JADX WARN: Removed duplicated region for block: B:342:0x0259  */
    /* JADX WARN: Removed duplicated region for block: B:347:0x026d  */
    /* JADX WARN: Removed duplicated region for block: B:368:0x0070 A[EXC_TOP_SPLITTER, SYNTHETIC] */
    /* JADX WARN: Removed duplicated region for block: B:379:0x01de A[EDGE_INSN: B:379:0x01de->B:309:0x01de ?: BREAK  , SYNTHETIC] */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
        To view partially-correct code enable 'Show inconsistent code' option in preferences
    */
    private static java.io.InputStream a(java.lang.String r19, java.util.Map<java.lang.String, java.lang.String> r20, long r21, int r23, com.esri.core.internal.io.handler.n r24, com.esri.core.internal.io.handler.ResponseListener r25) throws java.lang.Exception {
        /*
            Method dump skipped, instructions count: 661
            To view this dump change 'Code comments level' option to 'DEBUG'
        */
        throw new UnsupportedOperationException("Method not decompiled: com.esri.core.internal.io.handler.a.a(java.lang.String, java.util.Map, long, int, com.esri.core.internal.io.handler.n, com.esri.core.internal.io.handler.ResponseListener):java.io.InputStream");
    }
}
